﻿using System;
using Framework;

namespace Enterprise.Admin.Handle
{
    /// <summary>
    /// 获取文章分类详细JSON
    /// </summary>
    public partial class GetArticleCategoryDeatailJson : AdminBasePage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            var id = Fq("Id").SafeToInt();
            var articleCategoryService = new ArticleCategoryService();
            var record = articleCategoryService.GetById(id);
            object result = new
               {
                   CoArticleCategoryId = record["CoArticleCategoryId"].SafeToInt(),
                   CoName = record["CoName"].SafeToString(),
                   CoParentName = record["CoParentName"].SafeToString(),
                   CoSort = record["CoSort"].SafeToInt(),
                   CoNameEn = record["CoNameEn"].SafeToString()
               };
            Json(result);
        }
    }
}